//
//  HGPageTitleView.h
//  PageController
//
//  Created by yu on 2018/4/6.
//  Copyright © 2018年 ma c. All rights reserved.
//

#import <UIKit/UIKit.h>
@class HGPageTitleView;
@protocol HGPageTitleViewDelegate <NSObject>

- (void)pageTitleView:(HGPageTitleView *)pageTitleView selectedIndex:(NSInteger)index;

@end

@interface HGPageTitleView : UIView

@property (nonatomic, weak)id<HGPageTitleViewDelegate> delegate;


- (instancetype)initWithFrame:(CGRect)frame andTitles:(NSArray *)titles;

//接收滑动的方法
- (void)setTitleViewWithProgress:(CGFloat)progress sourceIndex:(NSInteger)sourceIndex targetIndex:(NSInteger)targetIndex;
@end
